//
//  ViewController.m
//  KKLiveDemo
//
//  Created by leo on 2017/7/29.
//  Copyright © 2017年 leo. All rights reserved.
//

#import "KKPersonListViewController.h"

#import "KKLiveChatViewController.h"

@interface KKPersonListViewController ()

@end

@implementation KKPersonListViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

#pragma mark - UITableView methods

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
    return 1;
}

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    return 3;
}

- (UITableViewCell*)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier: @"UITableViewCellIdentifier" forIndexPath: indexPath];
    cell.textLabel.text = [NSString stringWithFormat: @"会话 %@",@(indexPath.row + 1)];
    return cell;
}

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    
    KKLiveChatViewController *chatViewController = [KKLiveChatViewController new];
    [self.navigationController pushViewController: chatViewController animated: true];
}

@end
